package ru.picman;

import ru.picman.util.GreenThread;

/**
 * This is the class that handles the 'BirdAI'. 'BirdAI' because
 * there is no AI really, except for moving the bird every tick.
 * 
 * @author Matthijs
 */
public class BirdAI
             extends GreenThread
{
	
	/**
	 * Constructs new BirdAI.
	 * 
	 * @param bird The bird this AI belongs to
	 */
	public BirdAI(Bird bird) {
		this.bird = bird;
	}
	
	/**
	 * Moves the bird and sleeps the time that is set as move delay.
	 * @see GreenThread#run()
	 */

	public void run() {
		bird.move();
		sleep(Unit.MOVE_DELAY);
	}
	
	//
	
	private final Bird bird;
	
}
